home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2007 January, February, March & April
/
Chip-Cover-CD-2007-02.iso
/
Pakiet bezpieczenstwa
/
mini Pentoo LiveCD 2006.1
/
mpentoo-2006.1.iso
/
livecd.squashfs
/
usr
/
lib
/
python2.4
/
site-packages
/
NumTut
/
mkpic.py
< prev
next >
Wrap
Text File
|
2006-01-20
|
288b
|
10 lines
import Image
import Numeric
import pickle
g = Image.open('greece.jpg')
greeceRGB = Numeric.fromstring(g.tostring(), 'b')
greeceRGB.shape = (724, 1065, 4)
greeceRGB = greeceRGB[::-3,::3,:3]
greeceRGB = Numeric.transpose(greeceRGB, (1,0,2))
pickle.dump(greeceRGB, open('greece.pik', 'wb'))